﻿using Microsoft.AspNetCore.Mvc;

namespace Shop.Core.Share
{
    public class AbstractService : IAppService
    {
        protected static ProblemDetails Problem(string msg, int code = 404)
            => new() { Status = code, Detail = msg };

        protected static AppResult Success()
            => new();

        protected static AppResult<T> Success<T>(T data)
            => new(data);
    }
}
